﻿@model InVision_Ticket.ViewModels.TicketView

@{
    ViewBag.Title = "Edit";
}

<h2>Edit</h2>

<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>

@using (Html.BeginForm()) {
    @Html.ValidationSummary(true)
    <fieldset>
        <legend>TicketView</legend>

        <div class="editor-label">
            @Html.LabelFor(model => model.TicketID)
        </div>
        <div class="editor-field">
            @Html.DisplayFor(model => model.TicketID)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Summary)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Summary)
            @Html.ValidationMessageFor(model => model.Summary)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Details)
        </div>
        <div class="editor-field">
            @Html.TextAreaFor(model => model.Details)
            @Html.ValidationMessageFor(model => model.Details)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.CreatedDateTime)
            <br />
            @Html.Raw(

        </div>
        <div class="editor-field">
            @Html.DisplayFor(model => model.CreatedDateTime)
            @Html.ValidationMessageFor(model => model.CreatedDateTime)
        </div>



        <div class="editor-label">
            @Html.LabelFor(model => model.Priority)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Priority)
            @Html.ValidationMessageFor(model => model.Priority)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.TicketType)
        </div>
        <div class="editor-field">
            @Html.DropDownListFor(model => model.TicketTypeID, new SelectList(Model.TicketTypeList, "TicketTypeID", "TicketType1"))
            @Html.ValidationMessageFor(model => model.TicketType)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.LastModifiedDateTime)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.LastModifiedDateTime)
            @Html.ValidationMessageFor(model => model.LastModifiedDateTime)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.ResolvedDateTime)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.ResolvedDateTime)
            @Html.ValidationMessageFor(model => model.ResolvedDateTime)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.CurrentlyEditByLoginID)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.CurrentlyEditByLoginID)
            @Html.ValidationMessageFor(model => model.CurrentlyEditByLoginID)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.LastModifiedBy)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.LastModifiedBy)
            @Html.ValidationMessageFor(model => model.LastModifiedBy)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.CreatedByLoginID)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.CreatedByLoginID)
            @Html.ValidationMessageFor(model => model.CreatedByLoginID)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.CreatedByCustomerID)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.CreatedByCustomerID)
            @Html.ValidationMessageFor(model => model.CreatedByCustomerID)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.LocationID)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.LocationID)
            @Html.ValidationMessageFor(model => model.LocationID)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.SystemID)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.SystemID)
            @Html.ValidationMessageFor(model => model.SystemID)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.SalesmanName)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.SalesmanName)
            @Html.ValidationMessageFor(model => model.SalesmanName)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.TechnicianName)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.TechnicianName)
            @Html.ValidationMessageFor(model => model.TechnicianName)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.CustomerContactName)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.CustomerContactName)
            @Html.ValidationMessageFor(model => model.CustomerContactName)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.CreatedByLogin)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.CreatedByLogin)
            @Html.ValidationMessageFor(model => model.CreatedByLogin)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.CreatedByCustomer)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.CreatedByCustomer)
            @Html.ValidationMessageFor(model => model.CreatedByCustomer)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.BusinessName)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.BusinessName)
            @Html.ValidationMessageFor(model => model.BusinessName)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.BusinessCustomer)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.BusinessCustomer)
            @Html.ValidationMessageFor(model => model.BusinessCustomer)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Phone)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Phone)
            @Html.ValidationMessageFor(model => model.Phone)
        </div>

        <p>
            <input type="submit" value="Save" />
        </p>
    </fieldset>
}

<div>
    @Html.ActionLink("Back to List", "Index")
</div>
